How to sort a string in java (without using api method)

visit shbcf.ru